package com.springcloud.common.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.springcloud.common.core.entity.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import java.io.Serializable;

/**
 * <p>
 *
 * </p>
 *
 * @author mori
 * @since 2019-11-04
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
public class Resource extends BaseEntity<Resource> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "resource_id", type = IdType.AUTO)
    private Integer resourceId;

    /**
     * 编码 随机生成
     */
    private String code;

    private Integer type;

    private Integer systemMenuId;

    private String url;

    private String method;

    private String description;


    @Override
    protected Serializable pkVal() {
        return this.resourceId;
    }

}
